import requests


class IhrmLogin:
    @staticmethod
    def login(req_body):
        return requests.post(url="http://ihrm2-test.itheima.net/api/sys/login",
                             json=req_body)


if __name__ == '__main__':
    ihrm_login = IhrmLogin()
    req_data = {"mobile": "13800000002", "password": "123456"}
    ret = ihrm_login.login(req_data)
    print("登录", ret.json())
